package Mangos::DB::Characters::GuildMember;

use strict;
use warnings;

use base qw(Mangos::DB::Characters);

__PACKAGE__->meta->setup
(
    table   => 'guild_member',

    columns =>
    [
        guildid            => { type => 'integer', default => '0', not_null => 1 },
        guid               => { type => 'integer', default => '0', not_null => 1 },
        rank               => { type => 'tinyint', default => '0', not_null => 1 },
        pnote              => { type => 'varchar', default => '',  not_null => 1 },
        offnote            => { type => 'varchar', default => '',  not_null => 1 },
        BankResetTimeMoney => { type => 'integer', default => '0', not_null => 1 },
        BankRemMoney       => { type => 'integer', default => '0', not_null => 1 },
        BankResetTimeTab0  => { type => 'integer', default => '0', not_null => 1 },
        BankRemSlotsTab0   => { type => 'integer', default => '0', not_null => 1 },
        BankResetTimeTab1  => { type => 'integer', default => '0', not_null => 1 },
        BankRemSlotsTab1   => { type => 'integer', default => '0', not_null => 1 },
        BankResetTimeTab2  => { type => 'integer', default => '0', not_null => 1 },
        BankRemSlotsTab2   => { type => 'integer', default => '0', not_null => 1 },
        BankResetTimeTab3  => { type => 'integer', default => '0', not_null => 1 },
        BankRemSlotsTab3   => { type => 'integer', default => '0', not_null => 1 },
        BankResetTimeTab4  => { type => 'integer', default => '0', not_null => 1 },
        BankRemSlotsTab4   => { type => 'integer', default => '0', not_null => 1 },
        BankResetTimeTab5  => { type => 'integer', default => '0', not_null => 1 },
        BankRemSlotsTab5   => { type => 'integer', default => '0', not_null => 1 },
    ],

    relationships =>
    [

        Characters =>
        {
            type => 'one to one',
            class => 'Mangos::DB::Characters::Characters',
            column_map => { guid => 'guid' },
        }

    ],


    primary_key_columns => [ 'guildid' ],
);

1;

package Mangos::DB::Characters::GuildMember::Manager;

use strict;
use warnings;

use base 'Rose::DB::Object::Manager';

sub object_class { 'Mangos::DB::Characters::GuildMember' }

__PACKAGE__->make_manager_methods('guild_member');

1;
